import { createRequest } from '/@/api/service';
const module = 'ib/base/v1/emergencyDrillApi/';
/**
 * @function 应急演练查询接口（手机端）
 * @param data
 * @param header
 * @returns {Promise}
 */
function EMERGENCY_DRILL_QUERY_APP(
  data: EmergencyDrillApi.EmergencyDrillReq,
  header: object = {},
): Promise<EmergencyDrillApi.EmergencyDrillResp> {
  return createRequest(
    `${process.env.APP_API_URL}${module}emergencyDrillQueryApp`,
    data,
    header,
    'POST',
  );
}

/**
 * @function 应急演练详情(app)
 * @param data
 * @param header
 * @returns {Promise}
 */
function EMERGENCY_DRILL_APP_DETAIL(
  data: EmergencyDrillApi.EmergencyDrillDetailReq,
  header: object = {},
): Promise<EmergencyDrillApi.EmergencyDrillDetailResp> {
  return createRequest(
    `${process.env.APP_API_URL}${module}emergencyDrillAppDetail`,
    data,
    header,
    'POST',
  );
}

/**
 * 应急演练操作(app)
 * @param data
 * @param header
 * @returns
 */
function EMERGENCY_DRILL_APP_OPERATE(
  data: EmergencyDrillApi.EmergencyDrillAppOperateReq,
  header: object = {},
): Promise<EmergencyDrillApi.EmergencyDrillAppOperateResp> {
  return createRequest(
    `${process.env.APP_API_URL}${module}emergencyDrillAppOperate`,
    data,
    header,
    'POST',
  );
}

export { EMERGENCY_DRILL_QUERY_APP, EMERGENCY_DRILL_APP_DETAIL, EMERGENCY_DRILL_APP_OPERATE };
